Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Avoid prefixing with home when unnecessary #24230

Merged
merged 1 commit into from
Oct 3, 2024

Conversation

DonJayamanne
Copy link

@DonJayamanne DonJayamanne commented Oct 3, 2024

Fixes #24133

@@ -422,7 +422,10 @@ function getCustomVirtualEnvDirs(): string[] {
const venvFolders = getPythonSettingAndUntildify<string[]>(VENVFOLDERS_SETTING_KEY) ?? [];
const homeDir = getUserHomeDir();
if (homeDir) {
venvFolders.map((item) => path.join(homeDir, item)).forEach((d) => venvDirs.push(d));
venvFolders
.map((item) => (item.startsWith(homeDir) ? item : path.join(homeDir, item)))
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If the path was already rooted with home dir, we'd still prefix with home dir

@DonJayamanne DonJayamanne added skip package*.json package.json and package-lock.json don't both need updating skip tests Updates to tests unnecessary no-changelog No news entry required labels Oct 3, 2024
@vs-code-engineering vs-code-engineering bot added this to the October 2024 milestone Oct 3, 2024
@DonJayamanne DonJayamanne merged commit d072503 into microsoft:main Oct 3, 2024
42 of 46 checks passed
@DonJayamanne DonJayamanne deleted the don/issue24133 branch October 3, 2024 15:29
karthiknadig pushed a commit that referenced this pull request Oct 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
no-changelog No news entry required skip package*.json package.json and package-lock.json don't both need updating skip tests Updates to tests unnecessary
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Environments in paths defined in venvFolders not listed
2 participants